Optimal. Leaf size=30 \[ -\frac {\cos (a+b x)}{2 b}-\frac {\cos (3 a+3 b x)}{6 b} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.01, antiderivative size = 30, normalized size of antiderivative = 1.00, number of steps
used = 1, number of rules used = 1, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.062, Rules used = {4369}
\begin {gather*} -\frac {\cos (a+b x)}{2 b}-\frac {\cos (3 a+3 b x)}{6 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 4369
Rubi steps
\begin {align*} \int \cos (a+b x) \sin (2 a+2 b x) \, dx &=-\frac {\cos (a+b x)}{2 b}-\frac {\cos (3 a+3 b x)}{6 b}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.01, size = 15, normalized size = 0.50 \begin {gather*} -\frac {2 \cos ^3(a+b x)}{3 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.09, size = 27, normalized size = 0.90
method | result | size |
default | \(-\frac {\cos \left (x b +a \right )}{2 b}-\frac {\cos \left (3 x b +3 a \right )}{6 b}\) | \(27\) |
risch | \(-\frac {\cos \left (x b +a \right )}{2 b}-\frac {\cos \left (3 x b +3 a \right )}{6 b}\) | \(27\) |
norman | \(\frac {-\frac {4 \tan \left (\frac {a}{2}+\frac {x b}{2}\right ) \tan \left (x b +a \right )}{3 b}+\frac {4 \left (\tan ^{2}\left (\frac {a}{2}+\frac {x b}{2}\right )\right )}{3 b}+\frac {4 \left (\tan ^{2}\left (x b +a \right )\right )}{3 b}}{\left (1+\tan ^{2}\left (\frac {a}{2}+\frac {x b}{2}\right )\right ) \left (1+\tan ^{2}\left (x b +a \right )\right )}\) | \(79\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.27, size = 26, normalized size = 0.87 \begin {gather*} -\frac {\cos \left (3 \, b x + 3 \, a\right )}{6 \, b} - \frac {\cos \left (b x + a\right )}{2 \, b} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.21, size = 13, normalized size = 0.43 \begin {gather*} -\frac {2 \, \cos \left (b x + a\right )^{3}}{3 \, b} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 53 vs.
\(2 (24) = 48\).
time = 0.16, size = 53, normalized size = 1.77 \begin {gather*} \begin {cases} - \frac {\sin {\left (a + b x \right )} \sin {\left (2 a + 2 b x \right )}}{3 b} - \frac {2 \cos {\left (a + b x \right )} \cos {\left (2 a + 2 b x \right )}}{3 b} & \text {for}\: b \neq 0 \\x \sin {\left (2 a \right )} \cos {\left (a \right )} & \text {otherwise} \end {cases} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.40, size = 13, normalized size = 0.43 \begin {gather*} -\frac {2 \, \cos \left (b x + a\right )^{3}}{3 \, b} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.19, size = 43, normalized size = 1.43 \begin {gather*} \left \{\begin {array}{cl} x\,\left (2\,\sin \left (a\right )-2\,{\sin \left (a\right )}^3\right ) & \text {\ if\ \ }b=0\\ -\frac {3\,\cos \left (a+b\,x\right )+\cos \left (3\,a+3\,b\,x\right )}{6\,b} & \text {\ if\ \ }b\neq 0 \end {array}\right . \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________